package yz.com.javautil.roadNetwork;

import java.util.List;
import java.util.Vector;

/**
 * @author yuanzheng
 * @since 2022/11/2
 */
public class TestPath {
    public static void main(String[] args) {

        DenseGraphImpl g2 = new DenseGraphImpl(5, false);
        g2.addEdge(0, 1);
        g2.addEdge(0, 2);
        g2.addEdge(0, 3);
        g2.addEdge(1, 3);
        g2.addEdge(3, 4);


        AllPath path = new AllPath(g2, 0,4);
        List<Vector<Integer>> allPath = path.getAllPath();
        allPath.forEach(vector->{
            vector.forEach(v->{
                System.out.println(v);
            });
        });
    }
}
